package com.im.common.netty.my.codec;

import lombok.Data;

@Data
public class PrivateProtocol {
    private byte[] header;
    private byte[] body;
    private byte[] tail;

    public PrivateProtocol(byte[] body) {
        // 设置默认的头部信息和尾部信息
        this.header = new byte[] {0x01, 0x02};
        this.tail = new byte[] {0x0A, 0x0D};
        this.body = body;
    }

    public PrivateProtocol(byte[] header, byte[] body, byte[] tail) {
        this.header = header;
        this.body = body;
        this.tail = tail;
    }

}
